<template>
	<view class="WordIndex">
		<image class="logoimage" src="../../../static/logoself.png" mode=""></image>
		<view class="informore" @click="toDetail">
			<text>更多行程</text>
			<uni-icons type="right" size="14" color="#fff"></uni-icons>
		</view>
		<view class="payAlertBox">
			<button class="Online-button" open-type="contact">
					立即咨询
			</button>
			<view class="payButtonIndex" @click="toTutorial">查看详情</view>
		</view>
		<view class="scroll-hint">
			<uni-icons type="down" size="30" color="#fff"></uni-icons>
		</view>
	</view>
</template>

<script setup>
	import { routerGuard	} from '@/config/RouteGuard.js'
	import {
		ref,
		watchEffect
	} from 'vue'

	const shopId = ref()
	const props = defineProps({
		shopID: {
			type: Number,
			default: 0
		}
	})
	watchEffect(() => {
		shopId.value = props.shopID
		console.log('父组件传递的shopID', props.shopID);
	});
	const toDetail = () => {
		uni.navigateTo({
			url: '/pages/allDestination/allDestination?filterType=time'
		});
	}
	const toTutorial = () => {
		console.log('商品shopId.value', shopId.value)
		const url = `/homeSubpages/ProductDetails/index?ShopId=${shopId.value}`;
		routerGuard(url);
	}
</script>

<style scoped>
	.WordIndex {
		width: 100vw;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		position: absolute;
		top: 25vh;
		z-index: 12;
	}

	.payButton {
		width: 124px;
		height: 39px;
		display: flex;
		justify-content: center;
		align-items: center;
		border-radius: 28px;
		border: 1px solid white;
		color: white;
		font-family: "仓耳渔阳体 W05";

	}



	.IndexWord {
		color: white;
		font-size: 30px;
		font-family: "仓耳渔阳体 W05";
	}

	.payAlertBox {
		position: absolute;
		top: 60vh;
		z-index: 12;
		/* width: 100vw; */
		gap: 30rpx;
		display: flex;
		align-content: center;
		justify-content: space-between;
	}

	.logoimage {
		margin-top: -4vh;
		width: 120px;
		height: 120px;
	}

	.informore {
		margin-top: -4vh;
		font-weight: 400;
		width: 170rpx;
		height: 60rpx;
		border-radius: 25.58px;
		display: flex;
		justify-content: center;
		align-items: center;
		gap: 6rpx;
		color: #fff;
		font-size: 24rpx;
		background-color: rgba(92, 92, 92, 0.7);
	}

	.informore text {
		line-height: 24rpx;
		padding-bottom: 2rpx;
	}

	.informore :deep(.uni-icons) {
		display: flex;
		align-items: center;
	}

	.payButtonIndex {
		width: 170px;
		height: 38px;
		display: flex;
		justify-content: center;
		align-items: center;
		border-radius: 28px;
		background-color: white;
		color: black;
		font-family: "仓耳渔阳体 W05";
		font-size: 26rpx;
	}
	.Online-button {
		width: 160px;
		height: 38px;
		display: flex;
		justify-content: center;
		align-items: center;
		border-radius: 28px;
		border: 1px solid white;
		background-color: rgba(92, 92, 92, 0.4);

		color: white;
		font-family: "仓耳渔阳体 W05";
		font-size: 26rpx;
	}

	.scroll-hint {
		position: absolute;
		bottom: -58vh;
		left: 50%;
		transform: translateX(-50%);
		animation: bounce 1.5s infinite;
	}

	/* @keyframes bounce {
		0%, 100% {
			transform: translateX(-50%) translateY(0);
		}
		50% {
			transform: translateX(-50%) translateY(10px);
		}
	} */
</style>